package com.swpu.service_sleep.service;

import com.swpu.service_sleep.entity.SleepRecord;
import com.baomidou.mybatisplus.extension.service.IService;
import com.swpu.service_sleep.entity.SleepRecordVo;
import com.swpu.service_sleep.entity.SleepVo;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author chaichai
 * @since 2024-02-18
 */
public interface SleepRecordService extends IService<SleepRecord> {

    void saveUserSleepData(SleepRecord sleepRecord, String openid);

    List<SleepVo> getUserMonthData(String openid, String dayStr);

    SleepRecordVo getUserSleepChartData(String openid, Integer page, Integer pageSize);

    Double getAvgSleepHour(String openid, Integer days);
}
